package com.mscsoft.musicscore.note;

import com.alibaba.fastjson.annotation.JSONField;

/** 音符 */
public class Note {
   public final NoteType type;
   @JSONField(ordinal = 1)
   public final long tick;// 微秒
   @JSONField(ordinal = 2)
   public final long duration;
   @JSONField(ordinal = 3)
   public final int trackID;

   public enum NoteType {
      TAP, HOLD, SLIDE;
   }

   public Note(NoteType type, long tick, long duration, int trackID) {
      this.type = type;
      this.tick = tick;
      this.duration = duration;
      this.trackID = trackID;
   }
}